<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8" trimDirectiveWhitespaces="true"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="sql" uri="http://java.sun.com/jsp/jstl/sql" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>

<%--update.jsp에서 수정한 데이터를 BoardVO에 저장함 --%>

<fmt:requestEncoding value="UTF-8" />
<jsp:useBean id="bvo" class="dasom.model.BoardVO"/>
<jsp:setProperty name="bvo" property="*"/>


    <sql:update dataSource="jdbc/oracle11xe">
    	update board set bdtitle=?,userid=?,contents=?,regdate=sysdate where bdno=?
		<sql:param value="${bvo.bdtitle }"/>
		<sql:param value="${bvo.userid }"/>
		<sql:param value="${bvo.contents }"/>
		<sql:param value="${bvo.bdno }"/>
    </sql:update>
    
    <c:redirect url="view.jsp?bdno=${bvo.bdno }"/>